/**
 * 全局角色VO
 */
export interface globalRoleVo {
  createTime?: Date;
  creator?: string;
  creatorName?: string;
  /**
   * 创建人
   */
  creatorObject?: creatorObj;
  id?: string;
  modifier?: string;
  modifierName?: string;
  modifyTime?: Date;
  /**
   * 多语言名称
   */
  name?: { [key: string]: string };
  /**
   * 权限
   */
  permission?: customPermission;
  /**
   * 描述
   */
  remark?: string;
  tenantId?: string;
  [property: string]: any;
}

/**
 * 创建人
 *
 * 项目成员
 */
export interface creatorObj {
  /**
   * 头像
   */
  avatar?: string;
  /**
   * 用户id
   */
  id?: string;
  /**
   * 用户id名
   */
  name?: string;
  /**
   * 角色名
   */
  roleNameList?: { [key: string]: string }[];
  [property: string]: any;
}

/**
 * 权限
 *
 * 权限定义
 */
export interface customPermission {
  /**
   * 权限点
   */
  pointList?: PointList[];
  /**
   * 权限范围
   */
  scope?: Scope;
  fieldPermission?: any[];
  functionPermission?: any[];
  [property: string]: any;
}

/**
 * 权限点
 */
export enum PointList {
  ActualHours = "ACTUAL_HOURS",
  ActualTime = "ACTUAL_TIME",
  ChildTask = "CHILD_TASK",
  CreateTask = "CREATE_TASK",
  Curator = "CURATED",
  DeleteTask = "DELETE_TASK",
  Executor = "EXECUTOR",
  ExportTask = "EXPORT_TASK",
  ImportTask = "IMPORT_TASK",
  ManageDataflow = "MANAGE_DATAFLOW",
  PlannedHours = "PLANNED_HOURS",
  PlannedTime = "PLANNED_TIME",
  Priority = "PRIORITY",
  RefTask = "REF_TASK",
  TaskName = "TASK_NAME",
  TaskProgress = "TASK_PROGRESS",
  TaskType = "TASK_TYPE",
  TaskVersion = "TASK_VERSION",
  Transfer = "TRANSFER",
}

/**
 * 权限范围
 */
export enum Scope {
  All = "ALL",
  Assigned = "ASSIGNED",
  None = "NONE",
}

/**
 * 全局角色
 */
export interface globalRole {
  createTime?: Date;
  creator?: string;
  creatorName?: string;
  deleted?: string;
  i18nColumnMap?: { [key: string]: { [key: string]: any } };
  id?: string;
  modifier?: string;
  modifierName?: string;
  modifyTime?: Date;
  /**
   * 名称
   */
  name?: string;
  optimisticLocker?: number;
  /**
   * 权限json
   */
  permissionJson?: string;
  /**
   * 描述
   */
  remark?: string;
  tenantId?: string;
  [property: string]: any;
}
